package com.ruoyi.system.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDate;
import java.util.List;

/**
 * @author Yanzl
 * @version 1.0
 * @create: 2024/12/20 19:00
 * @description:
 */
@TableName(autoResultMap = true)
@Data
public class Back {
    @TableId(type = IdType.AUTO)
    private Long id;
    private String name;
    private String year;
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate startDate;
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate endDate;

    @TableField(typeHandler = JacksonTypeHandler.class)
    private List<String> person;
    @TableField(typeHandler = JacksonTypeHandler.class)
    private List<String> category;
}
